﻿using System;

namespace HslCommunication.Core.IMessage
{
	/// <summary>
	/// 横河PLC的以太网的二进制协议
	/// </summary>
	// Token: 0x02000164 RID: 356
	public class YokogawaLinkBinaryMessage : INetMessage
	{
		/// <inheritdoc cref="P:HslCommunication.Core.IMessage.INetMessage.ProtocolHeadBytesLength" />
		// Token: 0x17000610 RID: 1552
		// (get) Token: 0x06001DC7 RID: 7623 RVA: 0x0008D47D File Offset: 0x0008B67D
		public int ProtocolHeadBytesLength
		{
			get
			{
				return 4;
			}
		}

		/// <inheritdoc cref="M:HslCommunication.Core.IMessage.INetMessage.GetContentLengthByHeadBytes" />
		// Token: 0x06001DC8 RID: 7624 RVA: 0x0008DDDF File Offset: 0x0008BFDF
		public int GetContentLengthByHeadBytes()
		{
			return (int)this.HeadBytes[2] * 256 + (int)this.HeadBytes[3];
		}

		/// <inheritdoc cref="M:HslCommunication.Core.IMessage.INetMessage.CheckHeadBytesLegal(System.Byte[])" />
		// Token: 0x06001DC9 RID: 7625 RVA: 0x0008CD5E File Offset: 0x0008AF5E
		public bool CheckHeadBytesLegal(byte[] token)
		{
			return true;
		}

		/// <inheritdoc cref="M:HslCommunication.Core.IMessage.INetMessage.GetHeadBytesIdentity" />
		// Token: 0x06001DCA RID: 7626 RVA: 0x00047BE1 File Offset: 0x00045DE1
		public int GetHeadBytesIdentity()
		{
			return 0;
		}

		/// <inheritdoc cref="P:HslCommunication.Core.IMessage.INetMessage.HeadBytes" />
		// Token: 0x17000611 RID: 1553
		// (get) Token: 0x06001DCB RID: 7627 RVA: 0x0008DDF8 File Offset: 0x0008BFF8
		// (set) Token: 0x06001DCC RID: 7628 RVA: 0x0008DE00 File Offset: 0x0008C000
		public byte[] HeadBytes { get; set; }

		/// <inheritdoc cref="P:HslCommunication.Core.IMessage.INetMessage.ContentBytes" />
		// Token: 0x17000612 RID: 1554
		// (get) Token: 0x06001DCD RID: 7629 RVA: 0x0008DE09 File Offset: 0x0008C009
		// (set) Token: 0x06001DCE RID: 7630 RVA: 0x0008DE11 File Offset: 0x0008C011
		public byte[] ContentBytes { get; set; }

		/// <inheritdoc cref="P:HslCommunication.Core.IMessage.INetMessage.SendBytes" />
		// Token: 0x17000613 RID: 1555
		// (get) Token: 0x06001DCF RID: 7631 RVA: 0x0008DE1A File Offset: 0x0008C01A
		// (set) Token: 0x06001DD0 RID: 7632 RVA: 0x0008DE22 File Offset: 0x0008C022
		public byte[] SendBytes { get; set; }
	}
}
